const Router = require("koa-router");
const goodsController = require("../controller/goods");

let goods = new Router();
// 获取数据
goods.post("/getGoods", goodsController.getGoodsData);
goods.post("/getAllGoods", goodsController.getAllGoodsData);
goods.post("/add", goodsController.addGoods);
goods.post("/update", goodsController.updateGoods);
goods.post("/batchDetele", goodsController.batchDeteleGoods);
goods.post("/upload", goodsController.uploadImage);
goods.post("/getOne", goodsController.getOnlyGoodsData);
goods.post("/updateNum", goodsController.updateGoodsNum);

module.exports = goods;
